This application describes a method and apparatus that is capable of accurately determining the distance from a camera to an object using image-based measurements instead of time-of-flight measurements.